<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">
    {:token()}
    <div class="form-group">
        <label for="c-title" class="control-label col-xs-12 col-sm-2">{:__('Title')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-title" class="form-control" name="row[title]" type="text" value="">
        </div>
    </div>

    <div class="form-group">
        <label for="c-thumbs" class="control-label col-xs-12 col-sm-2">{:__('ThumbCdn')}:</label>
        <div class="col-xs-12 col-sm-8">
            <div class="input-group">
                <input id="c-thumbs" class="form-control" size="35" name="row[thumbs]" type="text" value="">
                <div class="input-group-addon no-border no-padding">
                    <span><button type="button" id="faupload-image" class="btn btn-danger faupload" data-input-id="c-thumbs" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp" data-multiple="false" data-preview-id="p-image"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
                    <span><button type="button" id="fachoose-image" class="btn btn-primary fachoose" data-input-id="c-thumbs" data-mimetype="image/*" data-multiple="false"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
                </div>
                <span class="msg-box n-right"></span>
            </div>
            <ul class="row list-inline faupload-preview" id="p-image"></ul>
        </div>
    </div>

    <!-- //价格 -->
    <div class="form-group">
        <label for="c-price" class="control-label col-xs-12 col-sm-2">{:__('Price')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-price" data-rule="required;price" class="form-control" name="row[price]" type="text" value="">
        </div>
    </div>

    <!-- 课程分类 -->
    <div class="form-group">
        <label for="c-cateid" class="control-label col-xs-12 col-sm-2">{:__('CategoryName')}:</label>
        <div class="col-xs-12 col-sm-8">
            <!-- 
                第一个参数 select name属性值
                第二个参数 数据源
                第三个参数 选中的值
                第四个参数 需要添加的属性
            -->
            {:build_select('row[cateid]',$CateData,null,['id' => 'c-cateid','class' => 'selectpicker'])}
        </div>
    </div>
    <!-- 课程老师 -->
    <div class="form-group">
        <label for="c-teacherid" class="control-label col-xs-12 col-sm-2">{:__('TeacherName')}:</label>
        <div class="col-xs-12 col-sm-8">
            {:build_select('row[teacherid]',$Teacher,null,['id' => 'c-teacherid','class' => 'selectpicker'])}
        </div>
    </div>

    <div class="form-group">
        <label for="c-content" class="control-label col-xs-12 col-sm-2">{:__('Content')}:</label>
        <div class="col-xs-12 col-sm-8">
            <textarea id="c-content" class="form-control editor" name="row[content]"></textarea>
        </div>
    </div>

    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-primary btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>